package com.jintian.smart.kernel.core.web;

/**
 * rest接口响应封装
 */
public class DefaultRestResultBuilder implements RestResultBuilder {

	@Override
	public Object data(Object data, String message) {
		if (data != null)
			return Result.data(data, message);
		else
			return Result.success(message);
	}

	@Override
	public boolean except(Object data) {
		return data instanceof Result;
	}

}
